package com.xiaohe.common.exception;

public enum BizCodeEnum {
    VALID_EXCEPTION(10001,"参数格式校验失败！"),
    UNKNOW_EXCEPTION(10000,"系统未知异常！"),
    PRODUCT_UP_ERROR(11000,"商品上架异常"),
    SMS_CODE_EXCEPTION(10002,"验证码获取频率太多，请稍后再试"),
    USER_EXIST_EXCEPTION(15001,"验证码获取频率太多，请稍后再试"),
    PHONE_EXIST_EXCEPTION(15002,"用户存在"),
    USERNAME_PASSWORD_ERROR(15003,"账户或者密码错误"),
    NO_STOCK_EXCEPTION(21000,"没有库存");
    private int code;
    private String msg;

     BizCodeEnum(int code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public int getCode() {
        return code;
    }

    public void setCode(int code) {
        this.code = code;
    }

    public String getMsg() {
        return msg;
    }

    public void setMsg(String msg) {
        this.msg = msg;
    }
}
